package com.lee.interview;

class Parent{
	
	String name ;
	
	int age;
	
	public Parent(){
		System.out.println("父类构造函数1");
	}
	
	public Parent(String name, int age) {
		this.name = name;
		this.age = age;
		System.out.println("父类构造函数2");
	}
	
}

class Child extends Parent {
	public Child(){
		System.out.println("子类构造函数1");
	}
	
	public Child(String name, int age) {
		this.name = name;
		this.age = age;
		System.out.println("子类构造函数2");
	}
}






public class ConstructorTest {
	public static void main(String[] args) {
		Parent parent = new Parent();
		Child child = new Child("123",25);
	}
}
